<template>
  <el-dialog
    top="30px"
    width="1000px"
    append-to-body
    :close-on-click-modal="false"
    :before-close="beforeClose"
    :visible.sync="visible"
  >
    <loan-approve
      :query-id="queryId"
      @dismiss="beforeClose()"
      @success="handleSuccess"
    ></loan-approve>
  </el-dialog>
</template>

<script>
import LoanApprove from '@/credit/views/county/unionProvince/components/loanApprove/Base'
export default {
  components: {
    LoanApprove,
  },
  props: {
    queryId: {
      type: String,
      required: true,
    },
    visible: Boolean,
  },
  data() {
    return {}
  },
  created() {},
  methods: {
    beforeClose() {
      this.$emit('update:visible', false)
    },
    handleSuccess() {
      this.$emit('success', true)
      this.beforeClose()
    },
  },
}
</script>
<style lang="scss" scoped></style>
